using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;
using Microsoft.Xna.Framework.Net;
using Microsoft.Xna.Framework.Storage;


namespace Mundo_3D
{
    class Manejador_Mundo : DrawableGameComponent
    {
       
        Mundo_Basico mundo;
        Cielo_Basico cielo;
        Manejador_Camaras cameramanager;
        string terreno;

        public Manejador_Mundo(Game game, Manejador_Camaras cam, string terr)  : base(game)
        {
            cameramanager = cam;
            terreno = terr;
        }

        public override void Initialize()
        {
            
            base.Initialize();
        }

        protected override void LoadContent()
        {
            mundo = new Mundo_Basico(Game.Content.Load<Model>(@"Textures\"+terreno));
            cielo = new Cielo_Basico(Game.Content.Load<Model>(@"Textures\sky4"));
            base.LoadContent();
        }

        public override void Update(GameTime gameTime)
        {
            base.Update(gameTime);
        }

        public override void Draw(GameTime gameTime)
        {
            Camara_Basica cam = cameramanager.getCamara();
            mundo.Draw(cam);
            cielo.Draw(cam);
            base.Draw(gameTime);
        }

    }
}